<script language="javascript" src="/js/script.js"></script>
<?php
class AML_View_Helper_AdminToolBar extends Zend_Controller_Action_Helper_Abstract
{
    public function adminToolBar($module, $action, $addurl, $editurl, $delurl, $backurl)
    {        
        switch($module) 
        {
            case "user" :
                $backurl = "/admin/user/";      
                break;
                
            case "hotel" :
            	$backurl = "/admin/hotel/";
            	break;    
        }
?>
		<div class="admintoolbar">
			<div class="title_text">
				<?php
					if($action == "index") {
				?>
					<h2><?php echo ucfirst($module); ?> Manager</h2>			
				<?php
					} else if($action == "add") {
				?>
					<h2>Add <?php echo ucfirst($module); ?></h2>
				<?php		
					}else if($action == "edit") {
				?>
					<h2>Edit <?php echo ucfirst($module); ?></h2>
				<?php
					}else if($action == "doadd") {
				?><h2>Add <?php echo ucfirst($module); ?></h2>
				<?php
					}else if($action == "doedit"){ ?>
                                <h2>Edit <?php echo ucfirst($module); ?></h2>
				<?php
					}?>

			</div>
    	
    		<div class="toolbarset">
	    		<?php
	    			if($action == "index") {
	    		?>
	    			<div style="float: left;"><a href="<?php echo $addurl; ?>"><img src="/images/admin/icons/save-1.gif" /><br />New</a></div>
	    			<div style="float: left; padding: 0 0 0 20px;"><a href="/admin/content/"><img src="/images/admin/icons/home.gif" /><br />Home</a></div>
	    			<!--<div style="float: left; padding: 0 0 0 20px;"><a href="javascript: void(0);" onclick="formEditData('/admin/<?php echo $module; ?>/edit/');"><img src="/images/admin/icons/edit.gif" /><br />Edit</a></div>
	    			<div style="float: left; padding: 0 0 0 20px;"><a href="/admin/<?php echo $module; ?>/delete/"><img src="/images/admin/icons/delete.gif" /><br />Trash</a></div>-->
	    		<?php
	    			} else if($action == "add") {
	    		?>
	    			<div style="float: left;"><a href="javascript: void(0);" title="" id="save<?php echo $module; ?>" onclick="save<?php echo $module; ?>();"><img src="/images/admin/icons/save-1.gif" /><br />Save</a></div>
	    			<div style="float: left; padding: 0 0 0 20px;"><a href="<?php echo $backurl; ?>" title="Back Page"><img src="/images/admin/icons/t-prv.gif" alt=""/><br />Back</a></div>
	    		<?php	
	    			} else if($action == "edit") {
	    		?>
	    			<div style="float: left;"><a href="javascript: void(0);" title="" id="update<?php echo $module; ?>" onclick="update<?php echo $module; ?>();"><img src="/images/admin/icons/save-2.gif" /><br />Update</a></div>
	    			<div style="float: left; padding: 0 0 0 20px;"><a href="<?php echo $backurl; ?>" title="Back Page"><img src="/images/admin/icons/t-prv.gif" alt=""/><br />Back</a></div>
	    		<?php
	    			}
	    		?>
	    	</div>
    	</div>
	    
<?php
    }
}
?>